package com.tuanbiao.base.action;


import android.view.Gravity;

import androidx.annotation.StringRes;

import com.hjq.toast.ToastUtils;


/**
 * author : Android 轮子哥
 * github : https://github.com/getActivity/AndroidProject
 * time   : 2019/12/08
 * desc   : 吐司意图
 */
public interface ToastAction {

    default void showShort(CharSequence text) {
        ToastUtils.setGravity(Gravity.CENTER);
        ToastUtils.show(text);
    }

    default void showShort(@StringRes int res) {
        ToastUtils.setGravity(Gravity.CENTER);
        ToastUtils.show(res);
    }
}